//
//  Environment.swift
//  BasicTools
//
//  Created by ikang on 2025/9/5.
//

import Foundation
import SwiftUI

// 配置导航栏颜色
private struct NavigationBackgroundColor: EnvironmentKey {
    static let defaultValue: Color = .white
}

public extension EnvironmentValues {
    public var navigationBackgroundColor: Color {
        get { self[NavigationBackgroundColor.self] }
        set { self[NavigationBackgroundColor.self] = newValue }
    }
}

public extension View {
    func navigationBackgroundColor(_ value: Color) -> some View {
        self.environment(\.navigationBackgroundColor, value)
    }
}




